﻿using System;
using System.Windows.Forms;
using Gladkikh.Sims2.Combiner.Database;

namespace Gladkikh.Sims2.Combiner.Controls
{

    public partial class Editor : Form
    {
        public Sims2Addon addon;

        public Editor(Sims2Addon add)
        {
            InitializeComponent();
            
            addon = add;

            textBox1.Text = add.Name;
            textBox2.Text = add.Exe;
            regBox.Text = add.RegMask;

        }

        private void saveButton_Click(object sender, EventArgs e)
        {
            addon.Name = textBox1.Text;
            addon.Exe = textBox2.Text;
            addon.RegMask = regBox.Text;
        }
    }
}